// pages/myads/myads.js
var app = getApp()

Page({
  data: {
    adsall:[]
  },
  start_adsbj:function(e){
    var addrid = e.currentTarget.id
    wx.navigateTo({
      url: '../myadsbj/myadsbj?addrid=' + addrid,
    })
  },
  start_adsxz: function () {
    wx.navigateTo({
      url: '../myadsxz/myadsxz',
    })
  },
  onLoad: function (options) {
  
  },
  onReady: function () {
  
  },
  onShow: function () {
    var that = this;
    wx.request({
      url : app.url + '/User/address',
      method:'post',
      data  : {
        uid : wx.getStorageSync('uid')
      },
      success : function(res){
        if (res.data.code == 1){
          that.setData({ adsall: res.data.data })
        }     
      },
      error   : function(){}
    })
  },
  onHide: function () {
  
  },
  onUnload: function () {
  
  },
  onPullDownRefresh: function () {
  
  },
  onReachBottom: function () {
  
  },
  onShareAppMessage: function () {
  
  }
})